import sys
import glob
import os

sub_dir = sys.argv[1]
current_dir = os.path.abspath('.')

file_path = sorted(glob.glob(os.path.join(current_dir, sub_dir, '*.c')))

for file in file_path:
    file_split = file.split('/')
    #file_name = './'+ '/'.join(file_split[-2:])
    file_name = file_split[-1].split('.')[0]
    print(file_name)
